package 线程的学习;

public class MyThread extends  Thread {
    private int a=0;

    @Override
    public void run() {
        for(int a=0;a<10;a++){
            System.out.println(currentThread().getName()+":"+a);
            try{
                sleep(100);
            }catch (InterruptedException e){
                throw new RuntimeException(e);
            }
        }
    }
}
